package Month09.day0909;

import java.util.Arrays;
import java.util.Scanner;

public class NiuKe {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String str = sc.next();
        String[] arr = str.split(";");
        String[] arr1  = arr[1].split(",");
        System.out.printf("The each subject score of  No. %d is %.2f, %.2f, %.2f.",Integer.parseInt(arr[0]),Float.parseFloat(arr1[0]),Float.parseFloat(arr1[1]),Float.parseFloat(arr1[2]));
    }//BC11 学生基本信息输入输出
    public static void main5(String[] args) {
        Scanner sc = new Scanner(System.in);
        String str = sc.next();
        char[] mystr = str.toCharArray();
        int count = 0;//计数器
        for (int i = 0; i < mystr.length; i++) {
            if(mystr[i] == 'C' || mystr[i] == 'H' || mystr[i] == 'N'){
                count++;
            }else if((mystr[i] == 'C' && mystr[i + 1] == 'H') ||(mystr[i] == 'C' && mystr[i + 1] == 'N') || (mystr[i] == 'N' && mystr[i + 1] == 'H')){
                count++;
            }else if(i < mystr.length - 3 && mystr[i] == 'C' && mystr[i + 1] == 'H' && mystr[i + 2] == 'N'){
                count++;
            }
        }
        System.out.println(count);
    }//BC119 小乐乐与字符串  (字符串转换为字符数组)(失败)
    public static void main4(String[] args) {
        //老师给了小乐乐一个正整数序列，要求小乐乐把这个序列去重后按从小到大排序。但是老师给出的序列太长了，小乐乐没办法耐心的去重并排序，请你帮助他。
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] arr = new int[n];
        for (int i = 0; i < arr.length; i++) {
            arr[i] = sc.nextInt();
        }
        Arrays.sort(arr);
        for (int i = 0; i < n; i++) {
            for (int j = 0; j < n; j++) {
                if(arr[i] != 0 && i != j && arr[i] == arr[j]){
                    arr[i] = 0;
                }
            }
        }
        for(int i:arr){
            if(i != 0){
                System.out.print(i + " ");
            }
        }
    }//BC118 小乐乐与序列(失败)
    public static void main3(String[] args) {
        //小乐乐喜欢数字，尤其喜欢0和1。他现在得到了一个数，想把每位的数变成0或1。如果某一位是奇数，就把它变成1，
        // 如果是偶数，那么就把它变成0。请你回答他最后得到的数是多少。
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int key = a;
        int count = 0;//计数器
        while(key != 0){
            key /= 10;
            count++;
        }
        int[] arr = new int[count];
        for (int i = arr.length - 1; i >= 0; i--) {
            arr[i] = (a % 10)%2  == 0  ? 0 : 1;
            a /= 10;
        }
        int sum = arr.length;//找第一个不为0的数字
        for (int i = 0; i < arr.length; i++) {
            if(arr[i] != 0){
                sum = i;
                break;
            }
        }
        if(sum == arr.length){
            System.out.println(0);
        }else{
        for (int i = sum; i < arr.length; i++) {
            System.out.println(arr[i]);
        }
        }
    }//BC116 小乐乐改数字
    public static void main2(String[] args) {
        Scanner sc = new Scanner(System.in);
        while(sc.hasNext()) {
            String sc1 = sc.next();//接收此刻时间
            int sum = sc.nextInt();//接收睡觉时间
            String[] arr1 = sc1.split(":");
            int hour = Integer.parseInt(arr1[0]);//此刻小时
            int min = Integer.parseInt(arr1[1]);//此刻分钟
            System.out.printf("%02d:%02d",(hour+(min + sum)/60)%24,(min + sum) % 60);
        }
        sc.close();;
    }//BC113 小乐乐定闹钟
    public static void main1(String[] args) {
        Scanner sc = new Scanner(System.in);
        char[][] str = new char[3][3];
        for (int i = 0; i < 3; i++) {
            for (int j = 0; j < 3; j++) {
                str[i][j] = sc.next().charAt(0);
            }
        }
        char s = jing(str);
        if(s == 'K'){
            System.out.println("KiKi wins!");
        }else if(s == 'B'){
            System.out.println("BoBo wins!");
        }else{
            System.out.println("No winner!");
        }
    }//BC110 井字棋
    public static char jing(char[][] str) {
        for (int i = 0; i < 3; i++) {
            if (str[i][0] == str[i][1] && str[i][1] == str[i][2]) {//判断行相等
                return str[i][0];
            } else if (str[0][i] == str[1][i] && str[1][i] == str[2][i]) {//判断列相等
                return str[0][i];
            } else if (str[0][0] == str[1][1] && str[1][1] == str[2][2]) {
                return str[0][0];
            } else if (str[0][2] == str[1][1] && str[1][1] == str[2][0]) {
                return str[0][2];
            }
        }
        return 'r';
    }
}
